package net.cyndeline.scalarlib.rldungeon.grammar.util

import net.cyndeline.scalarlib.rldungeon.dgs.graph.Room

/**
 * Produces default vertices with a unique id. When using multiple factory instances or sending the same factory to
 * multiple objects, it is up to the implementation(s) to synchronize their id generation internally to avoid giving
 * multiple rooms the same id.
 *
 * @tparam VType Type of vertex to produce.
 */
trait VertexFactory[VType <: Room[VType]] {
  def produce: VType
}
